using System;
using System.Collections;
using System.Collections.Generic;
using System.Threading;
using Notifications.Runtime;
using UnityEngine;

namespace Notifications.Test
{
    public class TestMainThread : MonoBehaviour
    {
        // Start is called before the first frame update
        void Start()
        {
            InvokeRepeating(nameof(Send), 1, 5);
        }

        private int id;

        private void Send()
        {
            id++;
            IGameNotification gameNotification = GameNotificationsManager.Instance.CreateNotification();
            gameNotification.Id = id;
            gameNotification.DeliveryTime = DateTime.Now;
            gameNotification.Body = "内容：" + id;
            gameNotification.Title = id.ToString();
            
      
            GameNotificationsManager.Instance.ScheduleNotification(gameNotification);
        }

        // Update is called once per frame
        void Update()
        {
        }
    }
}